<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>浮动产品布局</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }

        li{
            list-style: none ;
        }

        .product{
            width: 1226px;
            height: 628px;
            background-color: rgba(128, 128, 128, 0.1);
            margin: 0 auto;
        }
        .left{
            float: left;
            width: 234px;
            height: 628px;
            background-color: skyblue;
        }
        .right{
            float: right;
            width: 978px;
            height: 628px;
            background-color: cyan;
        }
        
        .right li{
            float: left;
            margin-top: 14px;
            margin-right: 14px;
            width: 234px;
            height: 300px;
            background-color: orange;
        }

        /* 找到第四个列和第八个列取消margin-right */
        .right li:nth-child(4n){
            margin-right: 0;
        }
    </style>
</head>
<body>
    <!-- 版心：左右结构。右面8个产品 -> 8个 li -->
    <div class="product">
        <div class="left"></div>
        <div class="right"><ui>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
        </ui></div>
    </div>
</body>
</html>